"""
BMI计算器

Version:1.0
Author:谢旗
"""
height = float(input('身高(cm)：'))
weight = float(input('体重(kg)：'))
bmi =weight/(height/100)**2
print(f'{bmi = :.1f}')
if 18.5 <=bmi <24:
    print('你的身材很棒！')
elif bmi<27:
    print('你的体重过重')
elif bmi<30:
    print('你已经轻度肥胖')
elif bmi<35:
    print('你已经中度肥胖')
else:
    print('你已经重度肥胖')

status_code = int(input('响应码：'))
match status_code:
    case 400|405:description = 'Invalid Request'
    case 401|403|404:description = 'Not Allowed'
    case 418:description = 'I am a teapot'
    case 429:description = 'Too many requests'
    case _:description ='Unknown Status Code'
print('状态码描述：',description)

a = float(input('a='))
b = float(input('b='))
c = float(input('c='))
if a+b>c and a+c>b and b+c>a:
    perimeter = a+b+c
    print(f'周长：{perimeter}')
    s = perimeter/2
    area = (s*(s-a)*(s-b)*(s-c))**0.5
    print(f'面积：{area}')
else:
    print('不能构成三角形')